package com.example.location;

import android.widget.Toast;

import com.baidu.mapapi.map.BaiduMap;
import com.baidu.mapapi.map.MapPoi;
import com.baidu.mapapi.model.LatLng;


/**
 * @ClassName:
 * @Description:点击选择位置
 * @author gongxibo
 * @date 创建时间：2015年12月18日 下午5:15:14
 */
public class SelectMylocationActivity extends ShowMylocationActivity {

	@Override
	protected void initListener() {
		mBaiduMap.setOnMapClickListener(new BaiduMap.OnMapClickListener() {

			@Override
			public boolean onMapPoiClick(MapPoi arg0) {
				// TODO Auto-generated method stub
				return false;
			}

			@Override
			public void onMapClick(LatLng arg0) {
				// System.out.println("projection = "+mBaiduMap.getProjection());

				
			  //mBaiduMap.clear(); 
			 // mBaiduMap.addOverlay(new
			 // MarkerOptions().position(arg0).icon( BitmapDescriptorFactory.fromResource(R.drawable.icon_marka)));
			 // mBaiduMap.setMapStatus(MapStatusUpdateFactory.newLatLng(arg0));

				Toast.makeText(context, arg0.toString(),Toast.LENGTH_SHORT).show();
				transLatLngToAddress(arg0);

			}
		});
	}


}
